Skip to main content

EstuaryClient.DealsApi

All URIs are relative to https://api.estuary.tech

MethodHTTP requestDescription
dealEstimatePostPOST /deal/estimateEstimate the cost of a deal
dealInfoDealidGetGET /deal/info/{dealid}Get Deal Info
dealProposalPropcidGetGET /deal/proposal/{propcid}Get Proposal
dealQueryMinerGetGET /deal/query/{miner}Query Ask
dealStatusByProposalPropcidGetGET /deal/status-by-proposal/{propcid}Get Deal Status by PropCid
dealStatusMinerPropcidGetGET /deal/status/{miner}/{propcid}Deal Status
dealTransferInProgressGetGET /deal/transfer/in-progressTransfer In Progress
dealsFailuresGetGET /deals/failuresGet storage failures for user
dealsMakeMinerPostPOST /deals/make/{miner}Make Deal
dealsStatusDealGetGET /deals/status/{deal}Get Deal Status
publicDealsFailuresGetGET /public/deals/failuresGet storage failures
publicMinersStorageQueryMinerGetGET /public/miners/storage/query/{miner}Query Ask
# **dealEstimatePost** > dealEstimatePost(body)

Estimate the cost of a deal

This endpoint estimates the cost of a deal

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var body = new EstuaryClient.MainEstimateDealBody(); // MainEstimateDealBody | The size of the deal in bytes, the replication factor, and the duration of the deal in blocks


var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealEstimatePost(body, callback);

Parameters

NameTypeDescriptionNotes
bodyMainEstimateDealBodyThe size of the deal in bytes, the replication factor, and the duration of the deal in blocks

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **dealInfoDealidGet** > dealInfoDealidGet(dealid)

Get Deal Info

This endpoint returns the deal info for a deal

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var dealid = 56; // Number | Deal ID


var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealInfoDealidGet(dealid, callback);

Parameters

NameTypeDescriptionNotes
dealidNumberDeal ID

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **dealProposalPropcidGet** > dealProposalPropcidGet(propcid)

Get Proposal

This endpoint returns the proposal for a deal

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var propcid = "propcid_example"; // String | Proposal CID


var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealProposalPropcidGet(propcid, callback);

Parameters

NameTypeDescriptionNotes
propcidStringProposal CID

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **dealQueryMinerGet** > dealQueryMinerGet(miner)

Query Ask

This endpoint returns the ask for a given CID

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var miner = "miner_example"; // String | CID


var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealQueryMinerGet(miner, callback);

Parameters

NameTypeDescriptionNotes
minerStringCID

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **dealStatusByProposalPropcidGet** > dealStatusByProposalPropcidGet(propcid)

Get Deal Status by PropCid

Get Deal Status by PropCid

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var propcid = "propcid_example"; // String | PropCid


var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealStatusByProposalPropcidGet(propcid, callback);

Parameters

NameTypeDescriptionNotes
propcidStringPropCid

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **dealStatusMinerPropcidGet** > dealStatusMinerPropcidGet(miner, propcid)

Deal Status

This endpoint returns the status of a deal

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var miner = "miner_example"; // String | Miner

var propcid = "propcid_example"; // String | Proposal CID


var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealStatusMinerPropcidGet(miner, propcid, callback);

Parameters

NameTypeDescriptionNotes
minerStringMiner
propcidStringProposal CID

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **dealTransferInProgressGet** > dealTransferInProgressGet()

Transfer In Progress

This endpoint returns the in-progress transfers

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealTransferInProgressGet(callback);

Parameters

This endpoint does not need any parameter.

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **dealsFailuresGet** > dealsFailuresGet()

Get storage failures for user

This endpoint returns a list of storage failures for user

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealsFailuresGet(callback);

Parameters

This endpoint does not need any parameter.

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **dealsMakeMinerPost** > dealsMakeMinerPost(miner, dealRequest)

Make Deal

This endpoint makes a deal for a given content and miner

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var miner = "miner_example"; // String | Miner

var dealRequest = "dealRequest_example"; // String | Deal Request


var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealsMakeMinerPost(miner, dealRequest, callback);

Parameters

NameTypeDescriptionNotes
minerStringMiner
dealRequestStringDeal Request

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **dealsStatusDealGet** > dealsStatusDealGet(deal)

Get Deal Status

This endpoint returns the status of a deal

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var deal = 56; // Number | Deal ID


var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.dealsStatusDealGet(deal, callback);

Parameters

NameTypeDescriptionNotes
dealNumberDeal ID

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **publicDealsFailuresGet** > publicDealsFailuresGet()

Get storage failures

This endpoint returns a list of storage failures

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.publicDealsFailuresGet(callback);

Parameters

This endpoint does not need any parameter.

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
# **publicMinersStorageQueryMinerGet** > publicMinersStorageQueryMinerGet(miner)

Query Ask

This endpoint returns the ask for a given CID

Example

var EstuaryClient = require('estuary-client');
var defaultClient = EstuaryClient.ApiClient.instance;

// Configure API key authorization: bearerAuth
var bearerAuth = defaultClient.authentications['bearerAuth'];
bearerAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//bearerAuth.apiKeyPrefix = 'Token';

var apiInstance = new EstuaryClient.DealsApi();

var miner = "miner_example"; // String | CID


var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.publicMinersStorageQueryMinerGet(miner, callback);

Parameters

NameTypeDescriptionNotes
minerStringCID

Return type

null (empty response body)

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json